package com.example.springbootelasticsearch.service;

import com.example.springbootelasticsearch.entity.ElasticSearch;
import org.springframework.data.elasticsearch.core.SearchHit;

import java.util.List;

public interface ElasticSearchService {
     void save(ElasticSearch elasticSearch);
     ElasticSearch findById(Integer id);
     void deleteById(Integer id);
     long count();
     boolean existById(Integer id);
    List<SearchHit<ElasticSearch>> findByTitleOrContent(String title, String content);

}
